package cn.itlaobing.web.filter;

import cn.itlaobing.web.filter.csjstag.CssJsTag;
import org.sitemesh.builder.SiteMeshFilterBuilder;
import org.sitemesh.config.ConfigurableSiteMeshFilter;

import javax.servlet.annotation.WebFilter;

/**
 * Created by Administrator on 2017-11-13.
 */
@WebFilter("/*")
public class Sitemesh extends ConfigurableSiteMeshFilter{
    @Override
    protected void applyCustomConfiguration(SiteMeshFilterBuilder builder) {
        builder.addExcludedPath("/home/skipLogin")
                .addDecoratorPath("/**","/WEB-INF/views/layout/application.jsp")
                .addExcludedPath("/assets/**")
                .addExcludedPath("/home/skipRegister")
        .addTagRuleBundle(new CssJsTag())
        .addExcludedPath("/register/register")
        ;
    }
}
